<script>
import { h } from 'vue'
export default {
  name: 'Bread',
  render(ctx) {
    const items = ctx.$slots.default()
    const arr = []
    items.map((item) => {
      arr.push(item)
      arr.push(h('i', { class: 'iconfont icon-angle-right' }))
    })

    arr.pop()

    return h('div', { class: 'bread' }, arr)
  }
}
</script>
<style lang="scss">
.bread {
  display: flex;
  padding: 25px 10px;

  &-item {
    a {
      color: #666;
      transition: all .4s;

      &:hover {
        color: $mainColor;
      }
    }
  }

  i {
    font-size: 12px;
    margin-left: 5px;
    margin-right: 5px;
    line-height: 22px;
  }
}
</style>